//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package com.itheima.pinda.authority.entity.common;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.itheima.pinda.authority.base.entity.SuperEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.time.LocalDate;
import java.time.LocalDateTime;
import org.hibernate.validator.constraints.Length;

@TableName("pd_common_login_log")
@ApiModel(
        value = "LoginLog",
        description = "登录日志"
)
public class LoginLog extends SuperEntity<Long> {
    private static final long serialVersionUID = 1L;
    @ApiModelProperty("操作IP")
    @Length(
            max = 50,
            message = "操作IP长度不能超过50"
    )
    @TableField(
            value = "request_ip",
            condition = "%s LIKE CONCAT('%%',#{%s},'%%')"
    )
    private String requestIp;
    @ApiModelProperty("登录人ID")
    @TableField("user_id")
    private Long userId;
    @ApiModelProperty("登录人姓名")
    @Length(
            max = 50,
            message = "登录人姓名长度不能超过50"
    )
    @TableField(
            value = "user_name",
            condition = "%s LIKE CONCAT('%%',#{%s},'%%')"
    )
    private String userName;
    @ApiModelProperty("登录人账号")
    @Length(
            max = 30,
            message = "登录人账号长度不能超过30"
    )
    @TableField(
            value = "account",
            condition = "%s LIKE CONCAT('%%',#{%s},'%%')"
    )
    private String account;
    @ApiModelProperty("登录描述")
    @Length(
            max = 255,
            message = "登录描述长度不能超过255"
    )
    @TableField(
            value = "description",
            condition = "%s LIKE CONCAT('%%',#{%s},'%%')"
    )
    private String description;
    @ApiModelProperty("登录时间")
    @TableField("login_date")
    private LocalDate loginDate;
    @ApiModelProperty("浏览器请求头")
    @Length(
            max = 500,
            message = "浏览器请求头长度不能超过500"
    )
    @TableField(
            value = "ua",
            condition = "%s LIKE CONCAT('%%',#{%s},'%%')"
    )
    private String ua;
    @ApiModelProperty("浏览器名称")
    @Length(
            max = 255,
            message = "浏览器名称长度不能超过255"
    )
    @TableField(
            value = "browser",
            condition = "%s LIKE CONCAT('%%',#{%s},'%%')"
    )
    private String browser;
    @ApiModelProperty("浏览器版本")
    @Length(
            max = 255,
            message = "浏览器版本长度不能超过255"
    )
    @TableField(
            value = "browser_version",
            condition = "%s LIKE CONCAT('%%',#{%s},'%%')"
    )
    private String browserVersion;
    @ApiModelProperty("操作系统")
    @Length(
            max = 255,
            message = "操作系统长度不能超过255"
    )
    @TableField(
            value = "operating_system",
            condition = "%s LIKE CONCAT('%%',#{%s},'%%')"
    )
    private String operatingSystem;
    @ApiModelProperty("登录地点")
    @Length(
            max = 50,
            message = "登录地点长度不能超过50"
    )
    @TableField(
            value = "location",
            condition = "%s LIKE CONCAT('%%',#{%s},'%%')"
    )
    private String location;

    public LoginLog(Long id, LocalDateTime createTime, Long createUser, String requestIp, Long userId, String userName, String account, String description, LocalDate loginDate, String ua, String browser, String browserVersion, String operatingSystem, String location) {
        this.id = id;
        this.createTime = createTime;
        this.createUser = createUser;
        this.requestIp = requestIp;
        this.userId = userId;
        this.userName = userName;
        this.account = account;
        this.description = description;
        this.loginDate = loginDate;
        this.ua = ua;
        this.browser = browser;
        this.browserVersion = browserVersion;
        this.operatingSystem = operatingSystem;
        this.location = location;
    }

    public static LoginLog.LoginLogBuilder builder() {
        return new LoginLog.LoginLogBuilder();
    }

    public String getRequestIp() {
        return this.requestIp;
    }

    public Long getUserId() {
        return this.userId;
    }

    public String getUserName() {
        return this.userName;
    }

    public String getAccount() {
        return this.account;
    }

    public String getDescription() {
        return this.description;
    }

    public LocalDate getLoginDate() {
        return this.loginDate;
    }

    public String getUa() {
        return this.ua;
    }

    public String getBrowser() {
        return this.browser;
    }

    public String getBrowserVersion() {
        return this.browserVersion;
    }

    public String getOperatingSystem() {
        return this.operatingSystem;
    }

    public String getLocation() {
        return this.location;
    }

    public LoginLog setRequestIp(final String requestIp) {
        this.requestIp = requestIp;
        return this;
    }

    public LoginLog setUserId(final Long userId) {
        this.userId = userId;
        return this;
    }

    public LoginLog setUserName(final String userName) {
        this.userName = userName;
        return this;
    }

    public LoginLog setAccount(final String account) {
        this.account = account;
        return this;
    }

    public LoginLog setDescription(final String description) {
        this.description = description;
        return this;
    }

    public LoginLog setLoginDate(final LocalDate loginDate) {
        this.loginDate = loginDate;
        return this;
    }

    public LoginLog setUa(final String ua) {
        this.ua = ua;
        return this;
    }

    public LoginLog setBrowser(final String browser) {
        this.browser = browser;
        return this;
    }

    public LoginLog setBrowserVersion(final String browserVersion) {
        this.browserVersion = browserVersion;
        return this;
    }

    public LoginLog setOperatingSystem(final String operatingSystem) {
        this.operatingSystem = operatingSystem;
        return this;
    }

    public LoginLog setLocation(final String location) {
        this.location = location;
        return this;
    }

    public LoginLog() {
    }

    public LoginLog(final String requestIp, final Long userId, final String userName, final String account, final String description, final LocalDate loginDate, final String ua, final String browser, final String browserVersion, final String operatingSystem, final String location) {
        this.requestIp = requestIp;
        this.userId = userId;
        this.userName = userName;
        this.account = account;
        this.description = description;
        this.loginDate = loginDate;
        this.ua = ua;
        this.browser = browser;
        this.browserVersion = browserVersion;
        this.operatingSystem = operatingSystem;
        this.location = location;
    }

    public String toString() {
        return "LoginLog(super=" + super.toString() + ", requestIp=" + this.getRequestIp() + ", userId=" + this.getUserId() + ", userName=" + this.getUserName() + ", account=" + this.getAccount() + ", description=" + this.getDescription() + ", loginDate=" + this.getLoginDate() + ", ua=" + this.getUa() + ", browser=" + this.getBrowser() + ", browserVersion=" + this.getBrowserVersion() + ", operatingSystem=" + this.getOperatingSystem() + ", location=" + this.getLocation() + ")";
    }

    public boolean equals(final Object o) {
        if (o == this) {
            return true;
        } else if (!(o instanceof LoginLog)) {
            return false;
        } else {
            LoginLog other = (LoginLog)o;
            if (!other.canEqual(this)) {
                return false;
            } else if (!super.equals(o)) {
                return false;
            } else {
                label145: {
                    Object this$requestIp = this.getRequestIp();
                    Object other$requestIp = other.getRequestIp();
                    if (this$requestIp == null) {
                        if (other$requestIp == null) {
                            break label145;
                        }
                    } else if (this$requestIp.equals(other$requestIp)) {
                        break label145;
                    }

                    return false;
                }

                Object this$userId = this.getUserId();
                Object other$userId = other.getUserId();
                if (this$userId == null) {
                    if (other$userId != null) {
                        return false;
                    }
                } else if (!this$userId.equals(other$userId)) {
                    return false;
                }

                Object this$userName = this.getUserName();
                Object other$userName = other.getUserName();
                if (this$userName == null) {
                    if (other$userName != null) {
                        return false;
                    }
                } else if (!this$userName.equals(other$userName)) {
                    return false;
                }

                label124: {
                    Object this$account = this.getAccount();
                    Object other$account = other.getAccount();
                    if (this$account == null) {
                        if (other$account == null) {
                            break label124;
                        }
                    } else if (this$account.equals(other$account)) {
                        break label124;
                    }

                    return false;
                }

                Object this$description = this.getDescription();
                Object other$description = other.getDescription();
                if (this$description == null) {
                    if (other$description != null) {
                        return false;
                    }
                } else if (!this$description.equals(other$description)) {
                    return false;
                }

                Object this$loginDate = this.getLoginDate();
                Object other$loginDate = other.getLoginDate();
                if (this$loginDate == null) {
                    if (other$loginDate != null) {
                        return false;
                    }
                } else if (!this$loginDate.equals(other$loginDate)) {
                    return false;
                }

                label103: {
                    Object this$ua = this.getUa();
                    Object other$ua = other.getUa();
                    if (this$ua == null) {
                        if (other$ua == null) {
                            break label103;
                        }
                    } else if (this$ua.equals(other$ua)) {
                        break label103;
                    }

                    return false;
                }

                Object this$browser = this.getBrowser();
                Object other$browser = other.getBrowser();
                if (this$browser == null) {
                    if (other$browser != null) {
                        return false;
                    }
                } else if (!this$browser.equals(other$browser)) {
                    return false;
                }

                label89: {
                    Object this$browserVersion = this.getBrowserVersion();
                    Object other$browserVersion = other.getBrowserVersion();
                    if (this$browserVersion == null) {
                        if (other$browserVersion == null) {
                            break label89;
                        }
                    } else if (this$browserVersion.equals(other$browserVersion)) {
                        break label89;
                    }

                    return false;
                }

                Object this$operatingSystem = this.getOperatingSystem();
                Object other$operatingSystem = other.getOperatingSystem();
                if (this$operatingSystem == null) {
                    if (other$operatingSystem != null) {
                        return false;
                    }
                } else if (!this$operatingSystem.equals(other$operatingSystem)) {
                    return false;
                }

                Object this$location = this.getLocation();
                Object other$location = other.getLocation();
                if (this$location == null) {
                    if (other$location == null) {
                        return true;
                    }
                } else if (this$location.equals(other$location)) {
                    return true;
                }

                return false;
            }
        }
    }

    protected boolean canEqual(final Object other) {
        return other instanceof LoginLog;
    }

    public int hashCode() {
        Boolean PRIME = true;
        int result = super.hashCode();
        Object $requestIp = this.getRequestIp();
        result = result * 59 + ($requestIp == null ? 43 : $requestIp.hashCode());
        Object $userId = this.getUserId();
        result = result * 59 + ($userId == null ? 43 : $userId.hashCode());
        Object $userName = this.getUserName();
        result = result * 59 + ($userName == null ? 43 : $userName.hashCode());
        Object $account = this.getAccount();
        result = result * 59 + ($account == null ? 43 : $account.hashCode());
        Object $description = this.getDescription();
        result = result * 59 + ($description == null ? 43 : $description.hashCode());
        Object $loginDate = this.getLoginDate();
        result = result * 59 + ($loginDate == null ? 43 : $loginDate.hashCode());
        Object $ua = this.getUa();
        result = result * 59 + ($ua == null ? 43 : $ua.hashCode());
        Object $browser = this.getBrowser();
        result = result * 59 + ($browser == null ? 43 : $browser.hashCode());
        Object $browserVersion = this.getBrowserVersion();
        result = result * 59 + ($browserVersion == null ? 43 : $browserVersion.hashCode());
        Object $operatingSystem = this.getOperatingSystem();
        result = result * 59 + ($operatingSystem == null ? 43 : $operatingSystem.hashCode());
        Object $location = this.getLocation();
        result = result * 59 + ($location == null ? 43 : $location.hashCode());
        return result;
    }

    public static class LoginLogBuilder {
        private Long id;
        private LocalDateTime createTime;
        private Long createUser;
        private String requestIp;
        private Long userId;
        private String userName;
        private String account;
        private String description;
        private LocalDate loginDate;
        private String ua;
        private String browser;
        private String browserVersion;
        private String operatingSystem;
        private String location;

        LoginLogBuilder() {
        }

        public LoginLog.LoginLogBuilder id(final Long id) {
            this.id = id;
            return this;
        }

        public LoginLog.LoginLogBuilder createTime(final LocalDateTime createTime) {
            this.createTime = createTime;
            return this;
        }

        public LoginLog.LoginLogBuilder createUser(final Long createUser) {
            this.createUser = createUser;
            return this;
        }

        public LoginLog.LoginLogBuilder requestIp(final String requestIp) {
            this.requestIp = requestIp;
            return this;
        }

        public LoginLog.LoginLogBuilder userId(final Long userId) {
            this.userId = userId;
            return this;
        }

        public LoginLog.LoginLogBuilder userName(final String userName) {
            this.userName = userName;
            return this;
        }

        public LoginLog.LoginLogBuilder account(final String account) {
            this.account = account;
            return this;
        }

        public LoginLog.LoginLogBuilder description(final String description) {
            this.description = description;
            return this;
        }

        public LoginLog.LoginLogBuilder loginDate(final LocalDate loginDate) {
            this.loginDate = loginDate;
            return this;
        }

        public LoginLog.LoginLogBuilder ua(final String ua) {
            this.ua = ua;
            return this;
        }

        public LoginLog.LoginLogBuilder browser(final String browser) {
            this.browser = browser;
            return this;
        }

        public LoginLog.LoginLogBuilder browserVersion(final String browserVersion) {
            this.browserVersion = browserVersion;
            return this;
        }

        public LoginLog.LoginLogBuilder operatingSystem(final String operatingSystem) {
            this.operatingSystem = operatingSystem;
            return this;
        }

        public LoginLog.LoginLogBuilder location(final String location) {
            this.location = location;
            return this;
        }

        public LoginLog build() {
            return new LoginLog(this.id, this.createTime, this.createUser, this.requestIp, this.userId, this.userName, this.account, this.description, this.loginDate, this.ua, this.browser, this.browserVersion, this.operatingSystem, this.location);
        }

        public String toString() {
            return "LoginLog.LoginLogBuilder(id=" + this.id + ", createTime=" + this.createTime + ", createUser=" + this.createUser + ", requestIp=" + this.requestIp + ", userId=" + this.userId + ", userName=" + this.userName + ", account=" + this.account + ", description=" + this.description + ", loginDate=" + this.loginDate + ", ua=" + this.ua + ", browser=" + this.browser + ", browserVersion=" + this.browserVersion + ", operatingSystem=" + this.operatingSystem + ", location=" + this.location + ")";
        }
    }
}
